// javamaps
// Copyright (c) 2010 Lup Gratian
package Rendering.Utils;
import java.util.*;

public final class BasicCollection<T> implements ObjectCollection<T> {
    private ArrayList<T> list_;

    /*
     * Constructori.
     */
    public BasicCollection() {
        list_ = new ArrayList<T>();
    }

    public BasicCollection(int capacity) {
        list_ = new ArrayList<T>(capacity);
    }

    /*
     * Metode publice.
     */
    public void Add(T value) { list_.add(value); }
    public boolean Valid(T value) { return true; }
    public void Remove(T value) { list_.remove(value); }
    public void Clear() { list_.clear(); }
    public int Count() { return list_.size(); }
    public Collection<T> Objects() { return list_; }
    public List<T> ObjectList() { return list_; }
}